<?php
$classname = "Outputter1";
$namespaces = "useful";
$path = "{$classname}.php";
if (!file_exists($path)) {
    throw new Exception("no such file as {$path}");
}
require_once($path);
$qclassname = "$namespaces\\$classname";

if (!class_exists($qclassname)) {
    throw new Exception("no such class as $qclassname");
}
//after check class
$testclass = new $qclassname();

$Object = $testclass->get_class();
echo get_class($Object);
//如果你使用get_class 必须要考虑命名空间是也写入前缀
if (get_class($Object) == 'Outputter1') {
    echo "it is true";
}else{
    echo "cannt knows it for the checks";
}
?>